<!DOCTYPE html >
<!--  Website template by freewebsitetemplates.com  -->
 <%@ page import="java.sql.*" %>
<html>

<head>
	<title>Cs</title>
	<meta  charset=iso-8859-1" />
	<link href="css/style.css" rel="stylesheet" type="text/css" />
	<!--[if IE 6]>
		<link href="css/ie6.css" rel="stylesheet" type="text/css" />
	<![endif]-->
	<!--[if IE 7]>
        <link href="css/ie7.css" rel="stylesheet" type="text/css" />  
	<![endif]-->
</head>

<body>

	  
			<div id="header">
	           		<a href="index.html" id="logo"><img src="images/logo.gif" width="310" height="72" alt="" title=""></a>
					<ul class="navigation">
						<li ><a href="index.html">Home</a></li>
						
						<li class="active"><a href="admin.jsp?label=userview">User_Details</a></li>
						
						
						
						<li><a href="logout4.jsp">Log out</a></li>
					</ul>
			</div>
			
			<div id="body">
			
			       <div id="content">
				         
						 
						 <div class="search">
									
								</div>
								
				        <div class="content8">
				        <% Object url=null,labels=null; 
				          labels=request.getParameter("label");
				        if(labels==null){
	%>
	<div style="width:900px;height:auto;float:left; border-radius:5px;margin-left:10px;margin-top:10px;margin-bottom:10px;border:1px solid #00cc00";>
	<%
	out.println("<br /><font size=\"5px\" color=\"green\" align=\"center\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Successfully Added</font></br /></br />");
	%></div>
	<%} %>
	
						
						        <% if(labels.equals("userview")){ 
	%>
	

<div style="width:900px;height:auto;float:left; border-radius:5px; padding-right:10px;padding-left:10px;padding-bottom:10px;padding-top:30px;margin-left:10px;margin-top:10px;margin-bottom:10px;border:1px solid #00cc00";>


<!--table start-->
<div class="admintablegenerator" ><font color="green" size="5px";>View Provider Details</font><br /><br />
                <table >
                    <tr>
                   
                        <td>
                           Email id
                        </td>
                       
                        <td >
                            Name
                        </td>
                         <td >
                            City
                        </td>
                        <td >
                            More Details..
                        </td>
                       
                        <td >
                            Upload And Download details.
                        </td>
                        
                    </tr>
                    
                    
                    <%
                    
                    String ad11=new String("");
                    
        			String ad12=new String("");
        			String ad13=new String("");
        			String ad14=new String("");
        			String ad15=new String("");
        			String ad16=new String("");
        			String ad17=new String("");
        			String ad18=new String("");
        			String ad19=new String("");
        			ResultSet rs12;
        			Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
        			Connection con1=DriverManager.getConnection("jdbc:odbc:encrypt","sa","test");
        		    Statement st=con1.createStatement();
        		    String sql12 = "select * from register" ;
        	 		st.executeQuery (sql12);
        	 		rs12 = st.getResultSet();
        			while (rs12.next ())
        				{
        				
        					
        					
        					ad13=rs12.getString("fname");
        					ad12=rs12.getString("email");
        					ad14=rs12.getString("city");
        					
        					
        					
        				%> 
                    
                    
                    <tr>
                        
                        <td>
                          <%=ad12%>
                        </td>
                         <td>
                          <%=ad13%>
                        </td>
                         <td>
                          <%=ad14%>
                        </td>
                         
                        
                        <td>
                         <a href="admin1.jsp?eid=<%=ad12%> &name=<%=ad13%>">see</a>
                        </td>
                         <td>
                         <a href="chart.jsp?eid=<%=ad12%> &name=<%=ad13%>">see</a>
                        </td>
                        
                        
                        <%} %>
                    </tr>
                   
                   
                </table>
                </div>



</div>
<%} %>
<% if(labels.equals("addkey")){ 
	%>
	

<div style="width:900px;height:auto;float:left; border-radius:5px; padding-right:10px;padding-left:10px;padding-bottom:10px;padding-top:30px;margin-left:10px;margin-top:10px;margin-bottom:10px;border:1px solid #00cc00";>


<!--table start-->
<div class="admintablegenerator" ><font color="green" size="5px";>View Url Details</font><br /><br />
                <table >
                    <tr>
                    <td>
                           MESSAGE ID
                        </td>
                    <td>
                           SENDER NUMBER
                        </td>
                        
                        <td>
                           RECEIVER NUMBER
                        </td>
                        
                       
                        
                         <td>
                          DATE
                        </td>
                         <td>
                         VIEW STATUS
                        </td>
                        <td>
                        TO SEE MESSAGE
                        </td>
                    </tr>
                    
                    
                    <%
                    String h=null;
                    String ad111=null;
                    String ad112=new String("");
                    String ad113=new String("");
                    String ad114=new String("");
                    String ad115=new String("");
                    String ad116=new String("");
                    String ad117=new String("");
        			int ad121=0;
        			int k=1;
        			ResultSet rs12;
        			Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
        			Connection con1=DriverManager.getConnection("jdbc:odbc:encrypt","sa","test");
        		    Statement st=con1.createStatement();
        		    String sql12 = "select * from message order by id desc;" ;
        	 		st.executeQuery (sql12);
        	 		rs12 = st.getResultSet();
        			while (rs12.next ())
        				{
        				int n=rs12.getInt("id");
        				
        					ad112=rs12.getString("sname");
        					ad117=rs12.getString("snumber");
        					
        					ad113=rs12.getString("rnumber");
        					
        					ad115=rs12.getString("date");
        					ad116=rs12.getString("seen");
        					
        					h=Integer.toString(n);
        					
        					
        				%> 
                    
                    
                    <tr>
                        <td>
                          <%=h%>
                        </td>
                        <td>
                          <%=ad117%>
                        </td>
                        
                        
                        
                        <td>
                          <%=ad113%>
                        </td>
                        
                        <td>
                          <%=ad115%>
                        </td>
                        <td>
                          <%=ad116%>
                        </td>
                         
                            <td>
                          <a href="admin2.jsp?eid=<%=h%> &sname=<%=ad112%>">see Message</a>
                        </td>
                        
                        <%} %>
                    </tr>
                   
                   
                </table>
                </div>
						<%} %>		
						</div>
						
					    <div id="sidebar">
								
                              								
								  
								
								
					    </div>
				   </div>
				   
				  
			
			</div>
			
			
			
	
</body>
</html>